import http from '@/utils/request.js'
import backURL from '@/api/router/requestUrl.js'

//获取教师的教学项目接口
export const getTeahProjList = (queryParams) => http.get(backURL.teachingProject,{ params: queryParams })

//文件上传接口
export const getFileUploadUrl = (file) => http({
  method: "post",
  url: backURL.fileUpload,
  data: { file: file },
  headers: {
    "Content-Type": "multipart/form-data"
  }
})

//添加教学项目接口
export const addTeachProj = (addForm) => http.post(backURL.teachingProject,addForm)

//删除教学项目接口
export const deleteTeachProj = (id) => http.delete(backURL.teachingProject + '/' + id)

//修改教学项目接口
export const changeTeachProj = (changeForm) => http({
  method: "put",
  url: backURL.teachingProject,
  data: changeForm,
  headers: {
    "Content-Type": "application/json"
  }
})

//根据成果id获取审核记录
export const getApprovalRecordList = (queryParams) => http.get(backURL.approvalRecord,{ params: queryParams })

